package com.qf.microsearch;

import com.qf.service.ISearchService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.CommandLineRunner;
import org.springframework.stereotype.Component;

@Component
public class AppRunListeener implements CommandLineRunner {
    @Autowired
    private ISearchService searchService;

    @Override
    public void run(String... args) throws Exception {

        System.out.println("构建ES索引库：" + searchService.createIndex());
    }
}
